# springboot基础镜像使用  --platform=amd64
# ARMv8 = ARM64 = AArch64
# ARMv7 = armv7l = ARM
# x86_64 = x64 = amd64
# x86 = x86_32
#FROM openjdk:21 as javaProject
FROM --platform=amd64 openjdk:21 as javaProject
MAINTAINER Bert <yanpldev@qq.com>
WORKDIR /app
# 要想在 FROM 之后使用，必须再次指定
ARG JAR_PATH
ARG JVM_ARG
# ENTRYPOINT 只认 ENV 环境变量
ENV APP_PATH=${JAR_PATH}
ENV TZ=Asia/Shanghai
COPY ${APP_PATH} /app/${APP_PATH}
#COPY docs/skywalking-agent.zip /app/skywalking-agent  删除
ENV JAVA_OPTS=${JVM_ARG}
ENTRYPOINT java -Djava.security.egd=file:/dev/./urandom ${JAVA_OPTS} -jar /app/${APP_PATH}